package cn.dubnation.base.query;


import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;

@AllArgsConstructor
@NoArgsConstructor
@Data
public class BaseQuery {
    private Integer currentPage;  //当前页
    private Integer pageSize;  //每页查询的数据条数
    private String keyword;  //关键字

    /**
     * #{}取值需要用到JavaBean属性的getter方法
     * @return
     */
    public int getStart() {
        return (currentPage - 1) * pageSize;
    }
}
